package com.prs.crm.domain.cqunicom;

import java.util.Set;

import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import com.prs.crm.domain.BaseEntity;

/**
 * @author WangTing
 * 
 *         创建时间：2011-3-4
 */

// ///////////////////////////////////////服务管理

@Entity
@Table(name = "cq_services")
public class Services extends BaseEntity {

	private static final long serialVersionUID = 1L;

	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	private Integer id;
	/**
	 * 业务短信消息是否使用
	 * 
	 * 1：未使用 2：已使用
	 */
	private String noteHand;

	/**
	 * 
	 * 服务名称
	 */

	private String name;
	/**
	 * 
	 * 名称简写
	 */
	private String simplename;

	/**
	 * 
	 * 备注
	 */
	private String remark;
	/**
	 * 
	 * 业务模式
	 */

	private String workPattern;

	/**
	 * 
	 * 服务类别
	 */

	private String type;

	@ManyToOne
	private ServicesType servicesType;

	@OneToMany(fetch = FetchType.LAZY, mappedBy = "services")
	private Set<PoplarOrder> poplarOrder;

	/**
	 * 中间表
	 * 
	 * @return
	 */
	@OneToMany(fetch = FetchType.LAZY, mappedBy = "servicesm")
	private Set<MidBusinessOrder> midBusinessOrder;

	@OneToMany(fetch = FetchType.LAZY, mappedBy = "servicestor")
	private Set<NoteEditor> noteEditor;

	@OneToMany(fetch = FetchType.LAZY, mappedBy = "servicesHigh")
	private Set<HighGradeExpected> highGradeExpected;

	public Set<HighGradeExpected> getHighGradeExpected() {
		return highGradeExpected;
	}

	public void setHighGradeExpected(Set<HighGradeExpected> highGradeExpected) {
		this.highGradeExpected = highGradeExpected;
	}

	public ServicesType getServicesType() {
		return servicesType;
	}

	public void setServicesType(ServicesType servicesType) {
		this.servicesType = servicesType;
	}

	public Integer getId() {
		return id;
	}

	public Set<MidBusinessOrder> getMidBusinessOrder() {
		return midBusinessOrder;
	}

	public void setMidBusinessOrder(Set<MidBusinessOrder> midBusinessOrder) {
		this.midBusinessOrder = midBusinessOrder;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getSimplename() {
		return simplename;
	}

	public void setSimplename(String simplename) {
		this.simplename = simplename;
	}

	public String getNoteHand() {
		return noteHand;
	}

	public void setNoteHand(String noteHand) {
		this.noteHand = noteHand;
	}

	public static long getSerialversionuid() {
		return serialVersionUID;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public String getWorkPattern() {
		return workPattern;
	}

	public void setWorkPattern(String workPattern) {
		this.workPattern = workPattern;
	}

	public static long getSerialVersionUID() {
		return serialVersionUID;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}

	public Set<PoplarOrder> getPoplarOrder() {
		return poplarOrder;
	}

	public void setPoplarOrder(Set<PoplarOrder> poplarOrder) {
		this.poplarOrder = poplarOrder;
	}

	public Set<NoteEditor> getNoteEditor() {
		return noteEditor;
	}

	public void setNoteEditor(Set<NoteEditor> noteEditor) {
		this.noteEditor = noteEditor;
	}

}
